import Vue from 'vue'
import Vuex from 'vuex'
Vue.use(Vuex)
// const homes  = require('./modules/homepages')
import homes from './modules/homepages'
import bags from './modules/bagPages'
import social from './modules/socialPages.js'
import my from './modules/myPages.js'
import login from './modules/loginPages.js'
import register from './modules/register.js'
import search from './modules/searchPage'
import VuexPersistence from 'vuex-persist'
const vuexLocal = new VuexPersistence({
    storage: window.localStorage
})
const store = new Vuex.Store({
    modules:{
        homes,
        bags,
        social,
        my,
        login,
        register,
        search
    },
    plugins: [vuexLocal.plugin]
})

export default store 